package com.easy.project.domain.dto.system;

import com.easy.project.base.validate.EnumValidate;
import com.easy.project.constant.BooleanEnum;
import com.easy.project.constant.NewTabEnum;
import com.easy.project.constant.StatusEnum;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotNull;

/**
 * 角色新增/修改的dto
 *
 * @author wxz
 */
@Data
@ApiModel("RoleEditDTO")
public class RoleEditDTO {

    @ApiModelProperty("id 有则修改 无则新增")
    private Long id;

    @ApiModelProperty("名称")
    @Length(min = 1, max = 50, message = "名称长度超出范围")
    private String roleName;

    @ApiModelProperty("编码")
    @Length(min = 1, max = 50, message = "编码长度超出范围")
    private String roleCode;

    @ApiModelProperty("状态 0 可用 1 不可用")
    @EnumValidate(baseEnum = StatusEnum.class,message = "状态的值错误")
    private Integer status;

}
